package 抽象类.抽象类特性.抽象类必须被继承;

/**
 * Created with IntelliJ IDEA.
 * Description:
 * User: 姚东名
 * Date: 2024-06-18
 * Time: 16:27
 */

//圆形
public class Circle extends Shape {
    private double r;
    final private static double Pl = 3.14;

    public Circle(double r) {
        this.r = r;
    }
    @Override
    public void draw() {
        System.out.println("圆：r = " + r);
    }

    @Override
    void calcArea() {
        area = Pl * r * r;
        //super.area = this.area * this.r * this.r;
    }
}
